﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace WFExtended.Twitter
{
    /// <summary>
    /// OAuth Tokens
    /// </summary>
    [DataContract]
    public class OAuthTokens
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="OAuthTokens"/> class.
        /// </summary>
        public OAuthTokens()
        { 
        
        }

        /// <summary>
        /// Creates OAuth Application Tokens
        /// </summary>
        /// <param name="consumerKey">The consumer key.</param>
        /// <param name="consumerSecret">The consumer secret.</param>
        /// <param name="applicationAccessToken">The application access token.</param>
        /// <param name="applicationAccessTokenSecret">The application access token secret.</param>
        /// <returns></returns>
        public static OAuthTokens Create(string consumerKey, string consumerSecret, string applicationAccessToken, string applicationAccessTokenSecret)
        {
            return new OAuthTokens()
            {
                ConsumerKey = consumerKey,
                ConsumerSecret = consumerSecret,
                ApplicationAccessToken = applicationAccessToken,
                ApplicationAccessTokenSecret = applicationAccessTokenSecret
            };
        }

        /// <summary>
        /// Gets or sets the consumer key.
        /// </summary>
        /// <value>
        /// The consumer key.
        /// </value>
        [DataMember]
        public string ConsumerKey { get; set; }

        /// <summary>
        /// Gets or sets the consumer secret.
        /// </summary>
        /// <value>
        /// The consumer secret.
        /// </value>
        [DataMember]
        public string ConsumerSecret { get; set; }


        /// <summary>
        /// Gets or sets the application access token.
        /// </summary>
        /// <value>
        /// The application access token.
        /// </value>
        [DataMember]
        public string ApplicationAccessToken { get; set; }


        /// <summary>
        /// Gets or sets the application access token secret.
        /// </summary>
        /// <value>
        /// The application access token secret.
        /// </value>
        [DataMember]
        public string ApplicationAccessTokenSecret { get; set; }

        /// <summary>
        /// Gets or sets the user access token.
        /// </summary>
        /// <value>
        /// The user access token.
        /// </value>
        [DataMember]
        public string UserAccessToken { get; set; }

        /// <summary>
        /// Gets or sets the user access token secret.
        /// </summary>
        /// <value>
        /// The user access token secret.
        /// </value>
        [DataMember]
        public string UserAccessTokenSecret { get; set; }
    }
}
